package multiplayer;

import Comunicator.PrimeraConexion;
import java.awt.Dimension;
import javax.swing.JApplet;


public class PanelController extends JApplet{
    private PanelPrincipal panelPrincipal;
    
    @Override
    public void init(){
        this.setSize(new Dimension(500, 500));
        this.setMaximumSize(new Dimension(500, 500));
        this.setMinimumSize(new Dimension(500, 500));
        this.setPreferredSize(new Dimension(500, 500));
        
        panelPrincipal = new PanelPrincipal();
        panelPrincipal.setSize(new Dimension(500, 500));
        panelPrincipal.setMaximumSize(new Dimension(500, 500));
        panelPrincipal.setMinimumSize(new Dimension(500, 500));
        panelPrincipal.setPreferredSize(new Dimension(500, 500));
        
        panelPrincipal.setVisible(true);
        panelPrincipal.setFocusable(true);
        
        this.add(panelPrincipal);
        PrimeraConexion primeraConexion = new PrimeraConexion(this);
        primeraConexion.connection();
        
        this.setVisible(true);
        this.setFocusable(true);
    }
    
    @Override
    public void start(){
        
    }

    public PanelPrincipal getPanelPrincipal() {
        return panelPrincipal;
    }
    
}
